package com.example.dto;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.example.model.dto.BaseDTO;
import com.example.mybatis.entity.BaseEntity;
import com.example.validator.group.AddGroup;
import com.example.validator.group.DefaultGroup;
import com.example.validator.group.UpdateGroup;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Null;
import lombok.Data;

import java.io.Serializable;

/**
 * 系统用户
 */
@Data
@Schema(description = "业务用户DTO")
public class BusinessUserDTO extends BaseDTO implements Serializable {
    private static final long serialVersionUID = 1L;
    private String openid;
    private String unionid;
    private String sessionKey;
    /**
     * id
     */
    @Null(message="{id.null}", groups = AddGroup.class)
    @NotNull(message="{id.require}", groups = UpdateGroup.class)
    @Schema(description = "id", required = false, example = "")
    private Long id;
    /**
     * 租户ID
     */
    @Schema(description = "租户ID", required = true, example = "1904755736660021249")
    @NotNull(message="{sysuser.username.require}", groups = DefaultGroup.class) // 字符串
    private Long tenantId;
    @Schema(description = "门店ID", required = true, example = "1904755736660021250")
    @NotNull(message="门店id不能为空", groups = DefaultGroup.class) // 字符串
    private Long storeId;
    @Schema(description = "isMember", required = false, example = "0")
    private Integer isMember;
    /**
     * 用户名
     */
    private String username;
    /**
     * 密码
     */
    private String password;
    /**
     * 姓名
     */
    private String realName;
    /**
     * 头像
     */
    private String avatarUrl;
    /**
     * 性别   0：男   1：女    2：保密
     */
    private Integer gender;
    /**
     * 邮箱
     */
    private String email;
    /**
     * 手机号
     */
    private String mobile;
    /**
     * 状态  0：停用   1：正常
     */
    private Integer status;
    /**
     * 备注
     */
    private String remark;
    /**
     * 删除标识  0：未删除    1：删除
     */
    private Integer delFlag;
}